package com.liu.service;


import com.liu.entity.Goods;
import com.liu.error.BusinessException;
import com.liu.vo.GoodsDetailVo;

import java.util.List;

public interface GoodsService {

    /**
     * 查看商品列表
     */
    public List<Goods> listGoods();

    /**
     * 商品详情浏览
     */
    GoodsDetailVo getGoodsById(Long goodsId);

    /**
     * 品销量增加
     */
    void increaseSales(Long goodsId, Integer amount) throws BusinessException;

    /**
     * 从缓存拿商品详情
     */
    GoodsDetailVo getGoodsByIdInCache(Long goodsId);

}
